project(IMGUI)
aux_source_directory(${IMGUI_PATH} IMGUI_SRCS)
add_library(${PROJECT_NAME}
    ${IMGUI_SRCS}
    ${IMGUI_PATH}/examples/imgui_impl_opengl3.cpp
    ${IMGUI_PATH}/examples/imgui_impl_glfw.cpp
)

# Base
set (
    BASE_SOURCE
    ${SABA_PATH}/src/Saba/Base/File.cpp
    ${SABA_PATH}/src/Saba/Base/Log.cpp
    ${SABA_PATH}/src/Saba/Base/Path.cpp
    ${SABA_PATH}/src/Saba/Base/Singleton.cpp
    ${SABA_PATH}/src/Saba/Base/Time.cpp
    ${SABA_PATH}/src/Saba/Base/UnicodeUtil.cpp
)
set (
    BASE_HEADER
    ${SABA_PATH}/src/Saba/Base/File.h
    ${SABA_PATH}/src/Saba/Base/Log.h
    ${SABA_PATH}/src/Saba/Base/Path.h
    ${SABA_PATH}/src/Saba/Base/Singleton.h
    ${SABA_PATH}/src/Saba/Base/Time.h
    ${SABA_PATH}/src/Saba/Base/UnicodeUtil.h
)

# OBJ Model
set (
    MODEL_OBJ_SOURCE
    ${SABA_PATH}/src/Saba/Model/OBJ/OBJModel.cpp
    ${SABA_PATH}/src/Saba/Model/OBJ/tinyobjloader.cpp
)
set (
    MODEL_OBJ_HEADER
    ${SABA_PATH}/src/Saba/Model/OBJ/OBJModel.h
)

# XFile Model
set (
    MODEL_XFILE_SOURCE
    ${SABA_PATH}/src/Saba/Model/XFile/XFileModel.cpp
)

set (
    MODEL_XFILE_HEADER
    ${SABA_PATH}/src/Saba/Model/XFile/XFileModel.h
)

# MMD Model
set (
    MODEL_MMD_SOURCE
    ${SABA_PATH}/src/Saba/Model/MMD/MMDIkSolver.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/MMDMaterial.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/MMDModel.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/MMDMorph.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/MMDNode.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/MMDPhysics.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/MMDCamera.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/PMDFile.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/PMDModel.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/PMXFile.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/PMXModel.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/SjisToUnicode.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/VMDAnimation.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/VMDCameraAnimation.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/VMDFile.cpp
    ${SABA_PATH}/src/Saba/Model/MMD/VPDFile.cpp
)
set (
    MODEL_MMD_HEADER
    ${SABA_PATH}/src/Saba/Model/MMD/MMDFileString.h
    ${SABA_PATH}/src/Saba/Model/MMD/MMDIkSolver.h
    ${SABA_PATH}/src/Saba/Model/MMD/MMDMaterial.h
    ${SABA_PATH}/src/Saba/Model/MMD/MMDModel.h
    ${SABA_PATH}/src/Saba/Model/MMD/MMDMorph.h
    ${SABA_PATH}/src/Saba/Model/MMD/MMDNode.h
    ${SABA_PATH}/src/Saba/Model/MMD/MMDPhysics.h
    ${SABA_PATH}/src/Saba/Model/MMD/MMDCamera.h
    ${SABA_PATH}/src/Saba/Model/MMD/PMDFile.h
    ${SABA_PATH}/src/Saba/Model/MMD/PMDModel.h
    ${SABA_PATH}/src/Saba/Model/MMD/PMXFile.h
    ${SABA_PATH}/src/Saba/Model/MMD/PMXModel.h
    ${SABA_PATH}/src/Saba/Model/MMD/SjisToUnicode.h
    ${SABA_PATH}/src/Saba/Model/MMD/VMDAnimation.h
    ${SABA_PATH}/src/Saba/Model/MMD/VMDCameraAnimation.h
    ${SABA_PATH}/src/Saba/Model/MMD/VMDAnimationCommon.h
    ${SABA_PATH}/src/Saba/Model/MMD/VMDFile.h
    ${SABA_PATH}/src/Saba/Model/MMD/VPDFile.h
)

add_library(
    Saba
    ${BASE_SOURCE}
    ${BASE_HEADER}
    ${MODEL_OBJ_SOURCE}
    ${MODEL_OBJ_HEADER}
    ${MODEL_XFILE_SOURCE}
    ${MODEL_XFILE_HEADER}
    ${MODEL_MMD_SOURCE}
    ${MODEL_MMD_HEADER}
)